exports.arrangeCustomerToSale = (req, res) => {

    var bodyParams = req.routeInfo.bodyParams;

    var resultData = {};

    var customerArr = bodyParams.customerArr;

    var u_id = bodyParams.u_id;

    function updateCustomer(cb) {

        F.ParallelEach(customerArr, function (item, index, callback) {

            //获取该代理下所有销售的订单数据
            R.SEND_HTTP(
                req,
                res,
                {
                    url: CORE_APIConfig.coreAPI.artCustomerUpdate.Request_Api_Url,
                    method: 'POST',
                    data: {
                        update_where: 'c_id',
                        c_id: item,
                        c_uid: u_id,
                        c_follow_status: 0,
                    }
                },
                function (data) {

                    console.log(data);

                    callback();

                }
            )
        }, cb);
    }


    F.Serial([
        updateCustomer,
    ], () => {
        RES.successResponse(res, resultData);
    })


}